import axios from '../../http'

const api = '/api/v2/goods/freight-price';

const error = (e) => {
  return () => console.error(e);
};

export default function getFreightPrice(params, cb, fcb = error('getFreightPrice')) {
  axios.get(api, {params}).then(response=> {
    cb(response.data);
  }).catch( response=> {
    fcb(response);
  })
}